import http from '@/utils/http'
/**
 * @description 获取角色列表
 * @returns
 */
export function fetchRoleBasic() {
    return http({
        url: '/v1/role/basic',
        method: 'get'
    })
}
/**
 * @description 获取菜单tree
 * @returns
 */
export function fetchRoleMenus() {
    return http({
        url: '/v1/role/menuTree',
        method: 'get'
    })
}
/**
 * @description 获取角色详情
 * @param {*} params
 * @returns
 */
export function fetchRoleInfo(params) {
    return http({
        url: '/v1/role/info',
        method: 'get',
        params: params
    })
}
/**
 * @description 新增角色
 * @param {*} params
 * @returns
 */
export function fetchRoleCreate(params) {
    return http({
        url: '/v1/role/create',
        method: 'post',
        data: params
    })
}
/**
 * @description 删除角色
 * @param {*} params
 * @returns
 */
export function fetchRoleRemove(params) {
    return http({
        url: '/v1/role/destroy',
        method: 'delete',
        params: params
    })
}
